home *** CD-ROM | disk | FTP | other *** search
- /*
- startServer.rexx
-
- This little ARexx macro starts up a ARexx server if its port
- isn't already available.
- I can't believe this isn't included in the standard ARexx
- distribution or libraries - hasn't every Amiga owner in the world
- had to write one of these by now?
-
- Inputs:
- arg 1 port ARexx port for the server
- arg 2 server The server's executable.
-
- Public domain. Use as you will.
- Author:
-
- --
- Glenn | ...!uunet!anagld!dahlgren!glenn (UUCP)
- Holliday | glenn@sed.csc.com (fully domained)
-
- */
- startServer.rexx:
-
- if (arg() < 2) then exit 1
- else do
- if ~(Show('P', arg(1))) then do
- address command 'run ' arg(2)
- address command 'WaitForPort ' arg(1)
- end
- end
- return 0
-